package com.cainiao.controller;

import org.springframework.stereotype.Controller;
import org.springframework.web.bind.annotation.RequestMapping;

/**
 * @author shkstart
 * @create 2021-08-04 10:35
 */
@Controller //把它作为 ioc容器
public class HelloController {
    // "/" -->WEB-INF/templates/index.html
    @RequestMapping(value = "/") //请求映射注解
    public String index() {
        //返回视图名称，视图名称决定了我们要跳转到页面
        return "index";
    }

    @RequestMapping("/target")
    public String toTarget() {
        return "target";
    }
}
